<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8" />

        <!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame
        Remove this if you use the .htaccess -->
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />

        <title>web03</title>
        <meta name="description" content="" />
        <meta name="author" content="Choongang31" />

        <meta name="viewport" content="width=device-width; initial-scale=1.0" />

        <!-- Replace favicon.ico & apple-touch-icon.png in the root of your domain and delete these references -->
        <link rel="shortcut icon" href="/favicon.ico" />
        <link rel="apple-touch-icon" href="/apple-touch-icon.png" />
        <script src="jquery.min.js"></script>
        <script>
            //ol 의 내용을 바꾸고 싶다 
            window.onload=function(){
                //li 요소 노드 집합의 개수를 알려줍니다 p70
                liArray=document.getElementsByTagName("li");
                console.log("li몇개 ",liArray.length,"개 ");
                //p75
                li_len = liArray.length;
                while(0<li_len--){
                    var li_text = liArray[li_len].firstChild.nodeValue;
                    console.log(li_text);
                }
                var $h1 = jQuery('h1');
                $h1.text("jQuery로 h1의 내용을 바꾸었습니다.");
            }
        </script>
    </head>

    <body>
        <div>
            <header>
                <h1>web03</h1>
            </header>
            <nav>
                <p>
                    <a href="/">Home</a>
                </p>
                <p>
                    <a href="/contact">Contact</a>
                </p>
            </nav>

            <div>
                   <ol>
                       <li>순서대로 </li>
                       <li>번호가 매겨지는 ol </li>
                       
                   </ol>
                   
            </div>

            <footer>
                <p>
                    &copy; Copyright  by Choongang31
                </p>
            </footer>
        </div>
    </body>
</html>
